home *** CD-ROM | disk | FTP | other *** search
/ Express Pd: GALORE / Express Pd Galore - The Amiga PD & Shareware CD (1994)(Express Pd)[!][Amiga-CD32-CDTV].iso / amicus / amicus_#1 / abasicstuff / tools / cardfile.bas < prev    next >
BASIC Source File  |  1985-12-04  |  15KB  |  469 lines

  1. 0     scnclr
  2. 1     y%=5 : rem Cardfile.bas
  3. 2     rgb 7,8,6,4
  4. 3     rgb 15,8,6,4
  5. 4     rgb 2,2,8,5
  6. 5     rgb 0,2,8,5
  7. 6     audio 15,1
  8. 7     screen 0,4
  9. 10    dim dm$(12),f$(9),m$(7),mi(8),sm$(18),y$(2700),yn$(1),z$(9)
  10. 20    e$=chr$(27):g$=chr$(7)
  11. 30    re$=chr$(10):sp$=chr$(32):ft=0:rt=0
  12. 40    yn$(0)="N":yn$(1)="Y":lm=1:sp=1:pf=0
  13. 50    hf=1:for i=1 to 7:read m$(i):next i
  14. 60    mi(0)=1:for i=1 to 7:read t:mi(i+1)=mi(i)+t
  15. 70    for j=mi(i) to mi(i+1)-1:read sm$(j):next j,i
  16. 80    for i=0 to 2:read dm$(i):next i
  17. 90    bl$=sp$:for i=1 to 36:bl$=bl$+sp$
  18. 100   l$=l$+chr$(61):next i:scnclr
  19. 105   goto 12000
  20. 110   pena 0:box(0,0;300,200),1:gosub 2400
  21. 115   on error goto 0
  22. 120   s%=sound(15,0,50,64,220)
  23. 125   '  MAIN MENU
  24. 130   '
  25. 131   pena 0:box(0,24;300,149),1
  26. 140   r$="Home Information Manager":gosub 2720
  27. 145   box(0,24;300,149),1
  28. 150   for i=1 to 6
  29. 160   ?tab(1);"<";i;"> ";m$(i);re$:next i
  30. 170   ?tab(5);"Selection -->";
  31. 180   a$="6":gosub 2300:ms=val(k$)
  32. 190   if k$=e$ then ms=7
  33. 200   if (ms <>3 and ms<>4) or rt>0 then 230
  34. 210   gosub 2700:?" No Cards Present."
  35. 220   gosub 2100:goto 110
  36. 230   on ms goto 240,560,900,1020,1340,1390,1890
  37. 240   FL=29:GOSUB 3000:if k$=e$ then 130
  38. 250   A$=STR$(FT):IF SE>2 OR RT<1 THEN 270
  39. 260   GOSUB 2710:GOSUB 2500:if K$=E$ then 240
  40. 265   rt=0
  41. 270   IF FT=0 AND SE>1 THEN 440
  42. 275   q=2
  43. 280   ON SE GOTO 290,370,460,530
  44. 290   GOSUB 3100:IF FT<9 THEN 320
  45. 300   ?"A Card has Only 9 Lines!"
  46. 310   GOSUB 2100:GOTO 240
  47. 320   FT=FT+1:C=FT
  48. 325   y%=5+ft
  49. 330   H$="Line "+STR$(C)+":":T$=""
  50. 340   GOSUB 6000:IF K$=E$ THEN FT=FT-1:GOTO 540
  51. 350   F$(FT)=T$:IF FT<9 THEN 290
  52. 360   gosub 3100:goto 310
  53. 370   GOSUB 3100:IF FT<1 THEN 450
  54. 380   A$=STR$(FT)
  55. 390   ?"Which Line do you Want to Delete? ";
  56. 400   gosub 2300:if k$=e$ then 540
  57. 410   c=val(k$):if c=ft then 430
  58. 420   for i=c to ft-1:f$(i)=f$(i+1):next i
  59. 430   ft=ft-1:if ft>0 then 370
  60. 440   gosub 2710
  61. 450   ?" No Lines Present.":gosub 2100:goto 540
  62. 460   gosub 3100
  63. 470   ?"Change the Name of Which Line #? ";
  64. 480   gosub 2300:if k$=e$ then 240
  65. 490   ?k$:c=val(k$)
  66. 500   h$="Line "+str$(c)+":":t$=f$(c)
  67. 505   y%=12
  68. 510   gosub 6000:if k$=e$ then 460
  69. 520   f$(c)=t$:goto 460
  70. 530   gosub 3100:goto 240
  71. 540   max=0:if ft>0 then max=int(2700/ft)
  72. 550   goto 240
  73. 560   y%=5:q=1:w$=e$:if ft>0 then 590
  74. 570   gosub 2700:?"You Must ";m$(1);" (option 1"
  75. 580   ?"on Main Menu) First.":gosub 2100:goto 110
  76. 590   if rt=max then gosub 2700:goto 650
  77. 600   gosub 3000:if k$=e$ then 110
  78. 610   gosub 2710:fl=38:if se=2 then 760
  79. 620   gosub 2600
  80. 630   rt=rt+1:if rt<max+1 then 660
  81. 640   rt=max
  82. 650   ?g$;dm$(2):gosub 2100:goto 110
  83. 660   ?at(15,4);"Card ";rt
  84. 670   c=rt:for l=1 to ft:gosub 3200
  85. 675   y%=y%+q
  86. 680   if k$<>e$ then y$(t)=t$:goto 700
  87. 690   l=ft:rt=rt-1
  88. 700   next L:if k$=e$ then 600
  89. 710   ?l$:?dm$(0)
  90. 720   ?at(1,20);"Cards Used: ";rt
  91. 730   ?at(1,21);"Cards Left: ";max-rt;sp$;
  92. 740   gosub 2200:on k$=sp$ goto 620:goto 130
  93. 750   gosub 2710:if rt=max then 650
  94. 760   h$="Insert Before Which Card #?":t$=""
  95. 765   y%=5
  96. 770   fl=39:gosub 6000:if k$=e$ then 600
  97. 780   gosub 2710
  98. 790   c=val(t$):if c>0 and c<rt+1 then 810
  99. 800   ?g$;dm$(1):gosub 2100:goto 590
  100. 810   ?tab(10);"New Card ";c
  101. 815   y%=5:q=1
  102. 820   y%=y%+q:for l=1 to ft:gosub 3200
  103. 825   y%=y%+q
  104. 830   if k$=e$ then L=ft:goto 850
  105. 840   z$(L)=t$
  106. 850   next L:if k$=e$ then 600
  107. 860   for j=rt*ft to (c-1)*ft+1 step -1
  108. 870   y$(j+ft)=y$(j):next j:rt=rt+1
  109. 880   for j=1 to ft:y$((c-1)*ft+j)=z$(j):next j
  110. 890   goto 750
  111. 900   f=-1
  112. 910   gosub 3000:if k$=e$ then 110
  113. 920   gosub 2710:if se =2 then 1010
  114. 925   box(0,24;300,159),1
  115. 930   h$="Start with Which Card?":t$="":fl=32
  116. 935   y%=5
  117. 940   gosub 6000:if k$=e$ then 910
  118. 950   v=val(t$):if v>0 and v<rt+1 then 970
  119. 960   ?at(0,10);l$:?dm$(1):gosub 2100:goto 910
  120. 970   gosub 3900:j=v
  121. 980   w$="":gosub 4000:if w$=e$ then 910
  122. 990   j=j+1:if j<rt+1 then 980
  123. 1000  box(0,0;300,175),1:?dm$(2):gosub 2100:goto 910
  124. 1010  gosub 5000:goto 910
  125. 1020  ra$=" (1-"+str$(rt)+")?"
  126. 1030  fl=6:gosub 3000:if k$=e$ then 110
  127. 1040  gosub 2710:on se goto 1050,1080,1130,1140,1150
  128. 1050  ?"Print which Card #";ra$
  129. 1055  y%=6
  130. 1060  gosub 3700:if rf then 1030
  131. 1070  r1=t:r2=t:gosub 3800:goto 1020
  132. 1080  ?"Start with which Card #";ra$
  133. 1085  y%=6
  134. 1090  gosub 3700:r1=t:if rf then 1030
  135. 1100  ?"Stop with which Card #";ra$
  136. 1105  y%=9
  137. 1110  gosub 3700:r2=t:if (rf) or r2<r1 then 1030
  138. 1120  gosub 3800:goto 1020
  139. 1130  r1=1:r2=rt:gosub 3800:goto 1020
  140. 1140  gosub 5000:goto 1020
  141. 1150  fl=37:h$="Left Margin (0-40):"
  142. 1155  y%=5
  143. 1160  t$=str$(lm)
  144. 1170  gosub 6000:if k$=e$ then 1020
  145. 1180  lm=val(t$):if lm> -1 and lm < 41  then 1210
  146. 1190  lm=1:?at(0,4);bl$
  147. 1200  ?at(1,4);:goto 1160
  148. 1210  h$="Blank Lines Between Cards (0-66):"
  149. 1215  y%=6
  150. 1220  t$=str$(sp)
  151. 1230  gosub 6000:if k$=e$ then 1020
  152. 1240  sp=val(t$):if sp > -1 and sp < 67 then 1270
  153. 1250  sp=0:?at(0,5);bl$
  154. 1260  ?at(1,5);:goto 1220
  155. 1270  h$="Pause after each Card (Y/N):":t$=yn$(pf)
  156. 1275  y%=7
  157. 1280  gosub 6000:if k$=e$ then 1020
  158. 1290  pf=(Left$(t$,1) = "Y")
  159. 1300  h$="Print Line Names (Y/N):":t$=yn$(hf)
  160. 1305  y%=8
  161. 1310  gosub 6000:if k$=e$ then 1020
  162. 1320  hf=(left$(t$,1) = "Y")
  163. 1330  ?l$:gosub 2100:goto 1020
  164. 1340  gosub 2700:on error goto 1370
  165. 1350  box(0,24;300,149),1
  166. 1360  ?: dir 
  167. 1370  ?l$:gosub 2400:gosub 2100
  168. 1380  on error goto 0:goto 110
  169. 1383  box(0,0;300,200),1
  170. 1385  goto 110
  171. 1390  fl=35:box(0,24;300,149),1
  172. 1395  y%=5
  173. 1400  gosub 3000: if k$=e$ then 110
  174. 1405  gosub 2400
  175. 1410  gosub 2710
  176. 1420  if se <> 2 or rt < 1 then 1440
  177. 1430  gosub 2500:box(0,24;300,139),1:if k$=e$ then 1400
  178. 1440  t$="":if se =1 then h$="Store under What Name?"
  179. 1450  if se=2 then h$="Get which Filebox?"
  180. 1460  if se=3 then h$="Remove which Filebox?"
  181. 1470  gosub 6000:if t$="" or k$=e$ then 1400
  182. 1480  if val(t$)<>0 or asc(t$) =48 then 1400
  183. 1485  che$=t$
  184. 1490  t$=t$+".him":box(0,25;300,149),1:on error goto 1510
  185. 1500  on se goto 1640,1790,1620
  186. 1510  '
  187. 1520  box(0,24;300,149),1
  188. 1530  close:?g$;
  189. 1535  er=err
  190. 1540  '
  191. 1550  if er=57 then ?"Disk I/O Error"
  192. 1560  if er=53 then ?"Filebox Not on This Disk"
  193. 1570  '
  194. 1580  if er=221 then ?"Sorry, this Disk is Full"
  195. 1600  close:?l$:gosub 2400:gosub 2100:resume 1400
  196. 1610  on error goto 0
  197. 1612  gosub 2400
  198. 1615  sleep 1*10^6:goto 1400
  199. 1620  scratch t$
  200. 1630  gosub 2400:goto 1610
  201. 1640  on error goto 0
  202. 1641  on error goto 14000
  203. 1650  open "i",#1,t$
  204. 1670  close :?g$;"That Filebox Already Exists"
  205. 1680  ?"Press <space bar> to Replace It."
  206. 1690  gosub 2400:gosub 2200:if k$=e$ then 1610
  207. 1700  box(0,24;300,149),1:scratch t$
  208. 1710  close #1:open "O",#1,t$
  209. 1720  cmd 1
  210. 1730  ?"FILEBOX":?ft:?rt
  211. 1740  ?lm:?sp:?pf:?hf
  212. 1750  for j=1 to ft:?f$(j)
  213. 1760  next j:if rt=0 then 1780
  214. 1770  for j=1 to rt*ft:?y$(j):next j
  215. 1780  cmd 0:close #1:on error goto 0:gosub 13000:gosub 2400:goto 1610
  216. 1790  open "i",#1,t$
  217. 1800  close:open "I",#1,t$
  218. 1810  '
  219. 1815  if lof(1) < 5 then er=53:goto 1530
  220. 1820  input#1, c$:if c$ <> "FILEBOX" then er=53:goto 1530
  221. 1830  input#1, ft,rt,lm,sp,pf,hf
  222. 1840  for j=1 to ft:line input#1, f$(j):next j:if rt=0 then 1860
  223. 1850  for j=1 to rt*ft:line input#1, y$(j):next j
  224. 1860  max=0:if ft>0 then max=int(2700/ft)
  225. 1870  cmd 0:close
  226. 1880  ?"Filebox is Now in Memory":getkey xr$:goto 110
  227. 1890  gosub 3000:if se=1 or k$=e$ then 110
  228. 1900  scnclr:end
  229. 2000  getkey k$:return
  230. 2100  gosub 2000: if k$<>e$ then 2100:return
  231. 2200  gosub 2000:if k$<>e$ and k$<>sp$ then 2200
  232. 2210  return
  233. 2300  getkey k$:?k$
  234. 2310  if k$ <> e$ and (k$ < "0" or k$ > a$) then 2300
  235. 2320  return
  236. 2400  ?at(0,23);l$
  237. 2405  s%=sound(15,0,30,64,582)
  238. 2410  ?at(10,24);"Press <Esc> to Exit";
  239. 2415  '?at(0,0);l$:?re$;l$
  240. 2420  return
  241. 2500  ?"Warning Use of this Option will Erase"
  242. 2510  ?"contents of All Cards from Memory."
  243. 2520  ?:?dm$(0):gosub 2200:return
  244. 2600  box(0,0;300,139),1:?at(0,0);:return
  245. 2700  box(0,0;300,151),1:r$=m$(ms):goto 2720
  246. 2710  box(0,24;300,151),1:r$=sm$(mi(ms)+se-1)
  247. 2720  ?at(0,0);l$:?re$;l$:?at(0,2);bl$:print at(0,2);
  248. 2730  ?spc((40-len(r$))/2);r$:?at(0,4):return
  249. 3000  gosub 2400:box(0,20;300,167),1:gosub 2700:?:for i=mi(ms) to mi(ms+1)-1
  250. 3010  ?tab(3);"<"i-mi(ms)+1"> "sm$(i)
  251. 3020  ?:next i:a$=str$(mi(ms+1)-mi(ms))
  252. 3030  ?:?tab(9)"Selection -->";
  253. 3040  gosub 2300:se=val(k$):return
  254. 3100  gosub 2710:if ft<1 then return
  255. 3110  ?"LIne";0;": All Lines"
  256. 3115  for i=1 to ft
  257. 3120  ?"Line";I;": ";f$(i):next i
  258. 3125  if ft>1 then q=1
  259. 3128  y%=y%+q
  260. 3130  ?L$:if ms=3 or ms=4 then return
  261. 3140  if se=4 then gosub 2100
  262. 3150  return
  263. 3200  t=(c-1)*ft+l:h$=f$(l)+":":t$=""
  264. 3210  if w$="C" then t$=y$(t)
  265. 3220  gosub 6000:return
  266. 3300  w$="":?tab(lm+15);"Card  ";j
  267. 3310  for z=1 to ft:t$="":if hf then t$=f$(z)+": "
  268. 3320  ?tab(lm);t$;y$((j-1)*ft+z)
  269. 3330  get w$:if w$=e$ then z=ft:j=r2
  270. 3340  next z:if w$=e$ then return
  271. 3350  if sp=0 then 3370
  272. 3360  for z=1 to sp:?:next z
  273. 3370  gosub 2600:if pf=0 then return
  274. 3380  close #2:cmd 0:?dm$(0):gosub 2200
  275. 3390  open "O",#2,"prt:":if k$=sp$ then return
  276. 3400  j=r2:return
  277. 3500  ?at(15,0);"Card ";j:?l$
  278. 3505  s%=sound(15,0,20,64,320)
  279. 3510  for z=1 to ft:?f$(z);" : ";y$((j-1)*ft+z)
  280. 3520  next z:?l$:return
  281. 3600  ?"Press <space> When Printer Ready"
  282. 3610  gosub 2200:return
  283. 3700  rf=1:h$="?":t$="":gosub 6000:?l$
  284. 3710  if k$=e$ or t$="" then return
  285. 3720  t=val(t$):if t>0 and t<=rt then rf=0:return
  286. 3730  ?g$;dm$(1):?l$
  287. 3740  gosub 2100:return
  288. 3800  gosub 3600:if k$=e$ then return
  289. 3810  open "O",#2,"prt:":cmd 2
  290. 3820  for j=r1 to r2:gosub 3300
  291. 3830  next j:cmd 0:close #2:return
  292. 3900  ?at(0,19);
  293. 3910  ?"Press <C> to Change this Card    "
  294. 3920  ?"Press <P> to Print Card"
  295. 3930  ?"Press <R> to Remove It, or           "
  296. 3940  ?"Press<space bar>to Move to Next Card.":return
  297. 4000  gosub 2600:gosub 3500
  298. 4010  gosub 2000:if k$=e$ then w$=e$:j=rt:return
  299. 4020  if k$=sp$ then return
  300. 4030  if k$="C" or k$="c" then 4110
  301. 4035  if k$="R" or k$="r" then 4170
  302. 4040  if k$="P" or k$="p" then 4050
  303. 4045  goto 4010
  304. 4050  box(0,24;300,139),1
  305. 4060  if f then gosub 3600:if k$=e$ then 4100
  306. 4070  f=0:?"Now Printing Card ";j
  307. 4080  open "O",#2,"prt:":cmd 2
  308. 4090  gosub 3300:cmd 0:close #2
  309. 4100  j=j-1:gosub 3900:return
  310. 4110  box(0,0;300,139),1:gosub 2710
  311. 4115  q=1:y%=6
  312. 4120  fl=39:?tab(15);"Card ";j
  313. 4130  c=j:w$="C":for l=1 to ft:gosub 3200
  314. 4135  y%=y%+1
  315. 4140  if k$=e$ then l=ft:goto 4160
  316. 4150  y$(t)=t$
  317. 4160  next l:j=j-1:gosub 3900:return
  318. 4170  box(0,24;300,139),1:gosub 3500
  319. 4180  ?"Press <space> to Remove This Card";
  320. 4190  gosub 2200:gosub 3900:if k$=e$ then j=j-1:return
  321. 4200  if j=rt then 4230
  322. 4210  for z=(j-1)*ft+1 to (rt-1)*ft
  323. 4220  y$(z)=y$(z+ft):next z
  324. 4230  rt=rt-1:j=j-1:return
  325. 5000  gosub 3110:a$=str$(ft)
  326. 5010  w$="":?"Select Cards by Which Line?";
  327. 5020  gosub 2300:if k$=e$ then return
  328. 5030  v=val(k$):gosub 2600
  329. 5032  bb=1
  330. 5035  if v=0 then bb=v:v=1
  331. 5040  y%=2:?"What Text to Search For?"
  332. 5050  fl=38:h$="?":t$="":gosub 6000
  333. 5060  if k$=e$ or t$="" then return
  334. 5070  box(0,24;300,139),1:?
  335. 5080  ?tab(5);"<1> Match from Begin or Line"
  336. 5090  ?re$;tab(5);"<2> Search Whole Line":?
  337. 5100  a$="2":?tab(9);"Selection -->";
  338. 5110  gosub 2300:if k$=e$ then return
  339. 5120  sf=0:sr$=t$:ls=len(sr$)
  340. 5130  j=1:if k$="2" then 5215
  341. 5140  box(0,0;300,139),1
  342. 5150  ?at(0,10);"Checking Card ";j
  343. 5160  if sr$ <> left$(y$((j-1)*ft+v),ls) then 5180
  344. 5170  sf=1:w$="":gosub 3900:gosub 4000:box(0,24;300,139),1
  345. 5180  get x$
  346. 5190  if w$=e$ or x$=e$ then return
  347. 5195  if bb=0 then v=v+1:if v<= ft then 5150
  348. 5200  j=j+1:if j<= rt then 5150
  349. 5210  goto 5330
  350. 5215  box(0,0;300,139),1
  351. 5220  z$=y$((j-1)*ft+v):lz=len(z$)
  352. 5230  ?at(0,10);"Checking Card ";j;" line ";v
  353. 5240  if z$="" then 5320
  354. 5250  for w=1 to lz-ls+1
  355. 5260  if sr$ <> Mid$(z$,w,ls) then 5280
  356. 5270  w=256:sf=1:w$="":gosub 3900:gosub 4000:box(0,0;300,139),1
  357. 5280  get x$
  358. 5290  if w$=e$ or x$=e$ then w=300
  359. 5300  next w
  360. 5310  if w$=e$ or (x$=e$ and k$<>e$) then return
  361. 5315  if bb=0 then v=v+1: if v<=ft then 5220 else v=1
  362. 5320  j=j+1:if j<rt+1 then 5220
  363. 5330  box(0,0;300,139),1:if sf<1 then 5350
  364. 5340  ?"No More Cards Match":gosub 2100:return
  365. 5350  ?"No Cards Match":gosub 2100:return
  366. 6000  ?at(0,y%);h$;:x%=pos(0)
  367. 6010  pc=2:t$=sp$+t$
  368. 6020  ?at(x%+1,y%);t$;
  369. 6030  ?at(x%+pc,y%);"";
  370. 6040  line input;k$
  371. 6042  if (w$="C" or w$="c") and len(k$)=0 then t$=y$(t):goto 6160
  372. 6044  if len(k$)=0 then k$=e$
  373. 6045  goto 6150
  374. 6050  if asc(kk$)<>155 and k > 31 then 6120
  375. 6060  er=(k=13)+(k=27):if er then 6150
  376. 6070  cu=(k=67)-(k=8):if k=4 then 6110
  377. 6080  if cu=0 then 6030
  378. 6090  pc=pc+cu:pc=pc+(pc<2)-(pc>len(t$)+1)
  379. 6100  goto 6030
  380. 6110  t$=left$(t$,pc-1)+mid$(t$,pc+1,len(t$)):goto 6020
  381. 6120  if len(t$) > fl-x%-1 then 6040
  382. 6130  t$=left$(t$,pc-1)+k$+mid$(t$,pc,len(t$))
  383. 6140  pc=pc+1:goto 6020
  384. 6150  t$=k$
  385. 6160  ?at(x%+2,y%);t$;sp$
  386. 6170  return
  387. 7000  DATA Design Card Format, Add Card(s)
  388. 7010  data Display/Change/Remove Card(s),Print Card(s)
  389. 7020  data List All Files on Disk
  390. 7030  data Get New/Store/Remove Filebox,Quit
  391. 7040  data 4,Add New Lines,Delete Lines
  392. 7050  data Change Names of Lines,Display Card Format
  393. 7060  data 2,Add at End,Insert Before End
  394. 7070  data 2,Look at Cards Consecutively
  395. 7080  data Work with Selected Card(s)
  396. 7090  data 5,Print One Card,Print a Range of Cards
  397. 7100  data Print All Cards,Print Selected Card(s)
  398. 7110  data Change Printer Options,1,Disk
  399. 7120  data 3,Store This Filebox on Disk
  400. 7130  data Get a Filebox from Disk
  401. 7140  data Remove a File from Disk
  402. 7150  data 2,Return to Main Menu,Quit
  403. 8000  data "Press <space bar> to continue."
  404. 8010  data No Such Card!,No More Cards
  405. 10000 scnclr
  406. 10010 rgb 4,12,1,1
  407. 10020 rgb 14,1,3,6
  408. 10030 peno 1
  409. 10040 outline 1
  410. 10050 graphic(1)
  411. 10060 x=144:y=24
  412. 10070 for num =1 to 7
  413. 10080 pena 13
  414. 10090 area(x,y to x+60,y to x+60,y-10 to x+140,y-10 to x+150,y to x+150,y+60 to x,y+60)
  415. 10100 pena 4:penb 13
  416. 10105 draw(x+140,y-10 to x+140,y to x+150,y)
  417. 10110 ?at(x+62,y-2);fa$(num)
  418. 10120 pena 14
  419. 10130 ?at(x+1,y+8);num
  420. 10140 x=x-16:y=y+16
  421. 10150 next
  422. 10160 z=2
  423. 10170 pena z mod 2:penb 0
  424. 10172 xx%=z*100
  425. 10174 if xx% > 800 then xx%=200:z=2
  426. 10175 s%=sound(15,0,20,64,xx%)
  427. 10176 audio 15,1
  428. 10180 ?at(10,10);"Select Folder # ?";:get ke$:if ke$ = "" then z=z+1 :pena z mod 2:sleep .4*10^6:goto 10170
  429. 10190 t$=fa$(val(ke$)):graphic(0)
  430. 10195 outline 0
  431. 10200 rgb 0,10,7,2
  432. 10210 rgb 2,10,7,2
  433. 10290 on error goto 11000
  434. 10300 t$=t$+".him"
  435. 10310 open "i",#1,t$
  436. 10320 input#1, c$:if c$<>"FILEBOX" then er=53:goto 1530
  437. 10330 input#1, ft,rt,lm,sp,fp,hf
  438. 10340 for j=1 to ft:input#1,f$(j):next j:if rt=0 then 10360
  439. 10350 for j=1 to rt*ft:input#1,y$(j):next j
  440. 10360 max=0:if ft>0 then max=int(2700/ft)
  441. 10370 close #1
  442. 10375 graphic(0)
  443. 10380 ?"Filebox is Now in Memory":?"Press a key            ":getkey xr$
  444. 11000 if err=53 then graphic(0):resume 110
  445. 11100 goto 110
  446. 12000 'on error goto 13000
  447. 12010 open "i",#3,"Index.him"
  448. 12030 for j=1 to 7
  449. 12040 input#3,fa$(j)
  450. 12060 next j:close #3
  451. 12065 on error goto 0
  452. 12070 goto 10000
  453. 13000 close
  454. 13010 open "o",#3,"Index.him"
  455. 13020 p$(1)="Address"
  456. 13030 ?#3,p$(1)
  457. 13050 for j=2 to 7
  458. 13060 p$(J)=fa$(j)
  459. 13070 next j
  460. 13080 if se=1 then p$(val(ke$))=che$
  461. 13090 for j=2 to 7
  462. 13100 ?#3,p$(j)
  463. 13110 next j
  464. 13115 close #3
  465. 13120 return
  466. 14000 resume 1710
  467. 65000 ' FAMILY COMPUTING NOV. 85
  468.  
  469.